<!DOCTYPE html>
<html lang="zh-cn">
<head>
    <meta charset="UTF-8">
    <title>lu_CostManagement_AboutOtherCost 费用管理-其他相关费用</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="Cache-Control" content="no-siteapp" />

    <link href="ADMIN_PUBLIC/css/bootstrap.min.css" rel="stylesheet">
    <link href="ADMIN_PUBLIC/css/animate.min.css" rel="stylesheet">
    <link href="ADMIN_PUBLIC/css/style.min.css" rel="stylesheet">
    <link href="ADMIN_PUBLIC/css/jquery.magnify.css" rel="stylesheet">
    <link href="https://cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet">
    <link rel="stylesheet" href="ADMIN_PUBLIC/fonts_style/iconfont.css">

    <link rel="stylesheet" href="ADMIN_PUBLIC/css/lu_common.css">
    <link rel="stylesheet" href="ADMIN_PUBLIC/css/lu_projectProgress.css">
    <link rel="stylesheet" href="ADMIN_PUBLIC/css/lu_CostManagement.css">
 
    <style>
        .add_hiddenBox{
            width:600px;
        }
    </style>
</head>
<body class="color_fff container-fluid row" style="background-color: #fff">
<include file = 'Common/cost_nav' />
<div class="row projectProgress_table_BOX">
    <div class="table_BOX">
        <table class="col-sm-12 table table-striped comTableStyle" id="table_table">
            <thead>
            <tr>
                <th><input type="checkbox" id="checkAll" class="checkboxStyle"></th>
                <th style="white-space: nowrap">凭证号</th>
                <th style="white-space: nowrap">日期</th>
                <th style="white-space: nowrap">借/贷选择</th>
                <!--<th style="white-space: nowrap">发生额(元)</th>-->
                <th style="white-space: nowrap">分类</th>
                <th>金额(元)</th>
                <th>摘要</th>
                <th>附件</th>
                <th style="white-space: nowrap">操作</th>
            </tr>
            </thead>
            <tbody>
        <volist name = 'data' id = 'v'>
            <tr data-index="{$v.id}">
                <td><input type="checkbox" class="checkboxStyle" <if condition = "$v.status == 1">disabled</if>></td>
                <td>{$v.vouch_sn}</td>
                <td>{$v.cost_time}</td>
                <td>{$v.cost_type}</td>
                <!--<td>{$v.cost_fmoney}</td>-->
                <td>{$v.cal_type}</td>
                <td>{$v.cost_tmoney}</td>
                <td class="look_record">
                    <a href="#" class="look_record_btn">查看</a>
                    <div class="tip_hiddenBox work_record_box">
                        <span class="work_record_title">工时记录</span>
                        <p class="work_record_main">{$v.cost_desc}</p>
                        <button class="btn btn-sm btn-success">确认</button>
                    </div>
                </td>
                <td><a href="look_img" class="edit_table">查看</a></td>
                <td><if condition = "$v.cost_type == '借' && $v.status == 0"><a href="edit_people" class="edit_table">编辑</a><else />-</if></td>
            </tr>
        </volist>
            </tbody>
        </table>
        <div class="pagination"><ul><li>{$page}</li></ul></div>
        <div class="hidden_box">
            <div class="hidden_box_showBox ">
                <span id="dateVal">筛选</span>
                <i class="iconfont icon-jiantou"></i>
            </div>
            <ul class="hidden_box_hiddenBox">
                <li class=" hidden_box_hiddenBox_list ">
                    <span class="hiddenBox_list_text">时间：</span>
                    <input type="text" class=" BFBFBF_inputStyle" id="query_time" data-query='time' autocomplete="off">
                </li>
                <li class=" hidden_box_hiddenBox_list ">
                    <span class="hiddenBox_list_text">借/贷选择：</span>
                    <!--<input type="text" class=" BFBFBF_inputStyle">-->
                    <select class="BFBFBF_inputStyle " name="" data-query='choose'>
                        <option></option>
                        <option value="1">借</option>
                        <option value="2">贷-资本化</option>
                        <option value="3">贷-费用化</option>
                    </select>
                </li>
                <li class="hiddenBox_list_btn">
                    <button class="btn btn-sm btn-success" id="query">确定</button>
                    <button class="btn btn-sm btn-success">查找全部</button>
                    <button class="btn btn-sm btn-default">取消</button>
                </li>
            </ul>
        </div>
        <ul class="operation_btn">
            <li><a href="add_people" class="btn btn-success">添加</a></li>
            <!--<li><a href="#" class="btn btn-success">批量添加</a></li>-->
            <li><a href="#delete" class="btn btn-success">批量删除</a></li>
        </ul>
        <ul class="animated fadeIn add_hiddenBox" lll="add_people" id="add_people">
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>凭证号：</label>
                <div class="col-sm-9 select_box">
                    <select class="form-control table_btn_list_selectStyle select_voucher" add_name="add_voucher_type">
                        <option>记</option>
                        <option>收</option>
                        <option>付</option>
                        <option>转</option>
                    </select>
                    <input type="text" class="BFBFBF_inputStyle add_people_input" placeholder=""  add_name="add_voucher_num" autocomplete="off">
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>日期：</label>
                <div class="col-sm-9">
                    <input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" id="add_time" add_name="add_time" autocomplete="off">
                </div>
            </li>
            <!--<li class="form-group table_btn_list">-->
                <!--<label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>借/贷选择：</label>-->
                <!--<div class="col-sm-9">-->
                    <!--&lt;!&ndash;<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_name">&ndash;&gt;-->
                    <!--<select class="form-control table_btn_list_selectStyle" add_name="add_borrowingChoose">-->
                        <!--<option value="1">借</option>-->
                        <!--<option value="2">贷-资本化</option>-->
                        <!--<option value="3">贷-费用化</option>-->
                    <!--</select>-->
                <!--</div>-->
            <!--</li>-->
            <!--<li class="form-group table_btn_list">-->
                <!--<label class="col-sm-3 control-label table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>发生额(元)：</label>-->
                <!--<div class="col-sm-9">-->
                    <!--<input type="number" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_happenMoney" autocomplete="off">-->
                <!--</div>-->
            <!--</li>-->
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>摘要：</label>
                <div class="col-sm-9">
                    <!--<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_SoftwareAmortization">-->
                    <textarea class="textarea_style" add_name="add_abstract"></textarea>
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>选择费用：</label>
                <div class="col-sm-9">
                    <!--<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_name">-->
                    <select class="form-control table_btn_list_selectStyle" add_name="add_Choose_cost">
                        <option value="1">技术图书资料费</option>
                        <option value="2">资料翻译费</option>
                        <option value="3">专家咨询费</option>
                        <option value="4">高新科技研发保险费</option>
                        <option value="5">研发成果的所需费用</option>
                        <option value="6">知识产权的所需费用</option>
                        <option value="7">职工福利费</option>
                        <option value="8">补充养老保险费</option>
                        <option value="9">补充医疗保险费</option>
                        <option value="10">差旅费、会议费</option>
                    </select>
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 control-label table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>费用金额(元)：</label>
                <div class="col-sm-9">
                    <input type="number" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_costMoney" autocomplete="off">
                </div>
            </li>
            <li class="form-group table_btn_list table_btn_list_top">
                <label class="col-sm-3 table_btn_list_title table_btn_list_title_top">附件：</label>
                <div class="col-sm-9 pz_file_box">
                    <button class="btn btn-success hidden_input_box">上传pdf文件<input type="file" accept="image/*" class="hidden_input" add_name="add_file"></button>
                    <ul class="pz_file_list">

                    </ul>
                </div>
            </li>
            <li class="button_list">
                <button class="btn btn-sm btn-success" id="add_btn">确认添加</button>
                <button class="btn btn-sm btn-success" id="add_AddNew_btn">添加并新增</button>
                <button class="btn btn-sm btn-default cancel_btn">取消</button>
            </li>
        </ul>
        <ul class="animated fadeIn add_hiddenBox" lll="edit_people" id="edit_people">
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>凭证号：</label>
                <div class="col-sm-9 select_box">
                    <select class="form-control table_btn_list_selectStyle select_voucher" add_name="edit_voucher_type">
                        <option>记</option>
                        <option>收</option>
                        <option>付</option>
                        <option>转</option>
                    </select>
                    <input type="text" class="BFBFBF_inputStyle add_people_input" placeholder=""  add_name="edit_voucher_num" autocomplete="off">
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>日期：</label>
                <div class="col-sm-9">
                    <input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" id="edit_time" add_name="edit_time" autocomplete="off">
                </div>
            </li>
            <!--<li class="form-group table_btn_list">-->
                <!--<label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>借/贷选择：</label>-->
                <!--<div class="col-sm-9">-->
                    <!--&lt;!&ndash;<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_name">&ndash;&gt;-->
                    <!--<select class="form-control table_btn_list_selectStyle" add_name="edit_borrowingChoose">-->
                        <!--<option value="1">借</option>-->
                        <!--<option value="2">贷-资本化</option>-->
                        <!--<option value="3">贷-费用化</option>-->
                    <!--</select>-->
                <!--</div>-->
            <!--</li>-->
            <!--<li class="form-group table_btn_list">-->
                <!--<label class="col-sm-3 control-label table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>发生额(元)：</label>-->
                <!--<div class="col-sm-9">-->
                    <!--<input type="number" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="edit_happenMoney" autocomplete="off">-->
                <!--</div>-->
            <!--</li>-->
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>摘要：</label>
                <div class="col-sm-9">
                    <!--<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_SoftwareAmortization">-->
                    <textarea class="textarea_style" add_name="edit_abstract"></textarea>
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>选择费用：</label>
                <div class="col-sm-9">
                    <!--<input type="text" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="add_name">-->
                    <select class="form-control table_btn_list_selectStyle" add_name="edit_Choose_cost">
                        <option value="1">技术图书资料费</option>
                        <option value="2">资料翻译费</option>
                        <option value="3">专家咨询费</option>
                        <option value="4">高新科技研发保险费</option>
                        <option value="5">研发成果的所需费用</option>
                        <option value="6">知识产权的所需费用</option>
                        <option value="7">职工福利费</option>
                        <option value="8">补充养老保险费</option>
                        <option value="9">补充医疗保险费</option>
                        <option value="10">差旅费、会议费</option>
                    </select>
                </div>
            </li>
            <li class="form-group table_btn_list">
                <label class="col-sm-3 control-label table_btn_list_title"><i class="iconfont icon-asterisk table_btn_list_necessary"></i>费用金额(元)：</label>
                <div class="col-sm-9">
                    <input type="number" class="col-sm-9 BFBFBF_inputStyle add_people_input" placeholder="" add_name="edit_costMoney" autocomplete="off">
                </div>
            </li>
            <li class="form-group table_btn_list table_btn_list_top">
                <label class="col-sm-3 table_btn_list_title table_btn_list_title_top">附件：</label>
                <div class="col-sm-9 pz_file_box">
                    <button class="btn btn-success hidden_input_box">上传pdf文件<input type="file" accept="image/*" class="hidden_input" add_name="edit_file"></button>
                    <ul class="pz_file_list">

                    </ul>
                </div>
            </li>
            <li class="button_list">
                <button class="btn btn-sm btn-success" id="save_btn">保存</button>
                <button class="btn btn-sm btn-default cancel_btn">取消</button>
            </li>
        </ul>
    </div>

    <!--内容没填完，弹框-->
    <div class="warning_hiddenBox animated fadeIn" id="yz_modal" box="yz_modal">
        您有内容没有填写完哦！
    </div>
    <!--删除人员-->
    <div class="add_hiddenBox animated fadeIn" id="delete" lll="delete">
        <p class="delete_tip_text">确认删除吗？</p>
        <div class="delete_tip_btn_box">
            <button class="btn btn-sm btn-success">确认</button>
            <button class="btn btn-sm btn-default">取消</button>
        </div>
    </div>
    <!--查看凭证-->
    <div class="add_hiddenBox animated fadeIn" id="look_img" lll="look_img" >
        <ul class="look_img_list">
            <li><a data-magnify="gallery" href="ADMIN_PUBLIC/img/a1.png"><img src="ADMIN_PUBLIC/img/ic_3@2x.png"></a></li>
            <li><a data-magnify="gallery" href="ADMIN_PUBLIC/img/a2.png"><img src="ADMIN_PUBLIC/img/ic_6@2x.png"></a></li>
            <li><a data-magnify="gallery" href="ADMIN_PUBLIC/img/a3.png"><img src="ADMIN_PUBLIC/img/ic_food2.png"></a></li>
            <li><a data-magnify="gallery" href="ADMIN_PUBLIC/img/a3.png"><img src="ADMIN_PUBLIC/img/ic_food2.png"></a></li>
            <li><a data-magnify="gallery" href="ADMIN_PUBLIC/img/a3.png"><img src="ADMIN_PUBLIC/img/ic_food2.png"></a></li>
        </ul>
        <div class="delete_tip_btn_box">
            <button class="btn btn-sm btn-success">确认</button>
        </div>
    </div>
</div>

<script src="ADMIN_PUBLIC/js/jquery.min.js"></script>
<script src="ADMIN_PUBLIC/js/jquery.magnify.js"></script>
<script src="ADMIN_PUBLIC/js/laydate/laydate.js"></script>
<script src="ADMIN_PUBLIC/js/lu_CostManagement_AboutOtherCost.js"></script>
<script>
    $(function(){
        $('[data-magnify=gallery]').magnify({
            headToolbar: [
                'close'
            ],
            footToolbar: [
                'zoomIn',
                'zoomOut',
                'prev',
                'fullscreen',
                'next',
                'actualSize',
                'rotateRight'
            ],
            title: false
        });

        window.query_time=''

        laydate.render({
            elem: '#query_time', //指定元素
            type: 'month',
            theme: '#2881C1',
            done: function(value, date, endDate){
                var dateVal = date.year+'年'+date.month+'月'
                window.query_time = dateVal
            }
        });
        laydate.render({
            elem: '#add_time', //指定元素
            theme: '#2881C1',
            done: function(value, date, endDate){
                // $.ajax({
                //     url:'/Admin/CostDesign/checkCost',
                //     type:'get',
                //     data:{
                //         time:value
                //     },
                //     success:function(data){
                //         if(data.code==1){
                //             if(data.data.length==0){
                //                 return
                //             }else{
                //                 let optionHTML = `
                //                     <option value="1">技术图书资料费</option>
                //                     <option value="2">资料翻译费</option>
                //                     <option value="3">专家咨询费</option>
                //                     <option value="4">高新科技研发保险费</option>
                //                     <option value="5">研发成果的所需费用</option>
                //                     <option value="6">知识产权的所需费用</option>
                //                     <option value="7">职工福利费</option>
                //                     <option value="8">补充养老保险费</option>
                //                     <option value="9">补充医疗保险费</option>
                //                 `
                //                 $('#add_people').find('[add_name=add_Choose_cost]').html(optionHTML)

                //                 console.log($('#add_people').find('[add_name=add_Choose_cost]'))
                //                 let optionList = $('#add_people').find('[add_name=add_Choose_cost]').children('option')
                //                 for(let di=0;di<data.data.length;di++){
                //                     for(let opi=0;opi<optionList.length;opi++){
                //                         let value = $(optionList[opi]).attr('value')
                //                         let removeID = data.data[di]
                //                         if(removeID == value){
                //                             $(optionList[opi]).remove()
                //                         }
                //                     }
                //                 }
                //             }
                //         }
                //         // if(data.code==1){
                //         //     let optionHTML = `
                //         //             <option value="1">技术图书资料费</option>
                //         //             <option value="2">资料翻译费</option>
                //         //             <option value="3">专家咨询费</option>
                //         //             <option value="4">高新科技研发保险费</option>
                //         //             <option value="5">研发成果的所需费用</option>
                //         //             <option value="6">知识产权的所需费用</option>
                //         //             <option value="7">职工福利费</option>
                //         //             <option value="8">补充养老保险费</option>
                //         //             <option value="9">补充医疗保险费</option>
                //         //         `
                //         //         $('#add_people').find('[add_name=add_Choose_cost]').html(optionHTML)

                //         //         console.log($('#add_people').find('[add_name=add_Choose_cost]'))
                //         //         let optionList = $('#add_people').find('[add_name=add_Choose_cost]').children('option')
                //         //         for(let di=0;di<data.data.length;di++){
                //         //             for(let opi=0;opi<optionList.length;opi++){
                //         //                 let value = $(optionList[opi]).attr('value')
                //         //                 let removeID = data.data[di]
                //         //                 if(removeID == value){
                //         //                     $(optionList[opi]).remove()
                //         //                 }
                //         //             }
                //         //         }
                //         //     }
                //         // }
                //     }
                // })
            }
        });
        laydate.render({
            elem: '#eait_time', //指定元素
            theme: '#2881C1',
            done: function(value, date, endDate){
                // $.ajax({
                //     url:'/Admin/CostDesign/checkCost',
                //     type:'get',
                //     data:{
                //         time:value
                //     },
                //     success:function(data){
                //         if(data.code==1){
                //             if(data.data.length==0){
                //                 return
                //             }else{
                //                 let optionHTML = `
                //                     <option value="1">技术图书资料费</option>
                //                     <option value="2">资料翻译费</option>
                //                     <option value="3">专家咨询费</option>
                //                     <option value="4">高新科技研发保险费</option>
                //                     <option value="5">研发成果的所需费用</option>
                //                     <option value="6">知识产权的所需费用</option>
                //                     <option value="7">职工福利费</option>
                //                     <option value="8">补充养老保险费</option>
                //                     <option value="9">补充医疗保险费</option>
                //                 `
                //                 $('#edit_people').find('[add_name=edit_Choose_cost]').html(optionHTML)

                //                 let optionList = $('#edit_people').find('[add_name=edit_Choose_cost]').children('option')
                //                 for(let di=0;di<data.data.length;di++){
                //                     for(let opi=0;opi<optionList.length;opi++){
                //                         let value = $(optionList[opi]).attr('value')
                //                         let removeID = data.data[di]
                //                         if(removeID == value){
                //                             $(optionList[opi]).remove()
                //                         }
                //                     }
                //                 }
                //             }
                //         }
                //     }
                // })
            }
        });

        // 弹出来的小框框
        function tipShow(){
            window.tipBox = setTimeout(function(){
                // $('#yz_modal').removeClass('active')
                // $('#yz_modal').addClass('fadeOut')
                $('#yz_modal').removeClass('active')
                clearTimeout(tipBox)
            },2000)
        }
    })
</script>
</body>
</html>